
<p><b>syntax:</b> <i>proxy_cache_key line;</i>
</p><p><b>default:</b> <i>$scheme$proxy_host$request_uri;</i>
</p><p><b>context:</b> <i>http, server, location</i>
</p><p>The directive specifies what information is included in the key for caching, for example
</p>
<pre class="code">  proxy_cache_key <span class="st0">&quot;$host$request_uri$cookie_user&quot;</span>;</pre>
<p>Note that by default, the hostname of the server is not included in the cache key. If you are using subdomains for different locations on your website, you need to include it, e.g. by changing the cache key to something like
</p>
<pre class="code">  proxy_cache_key <span class="st0">&quot;$scheme$host$request_uri&quot;</span>;</pre>
<br><i>Module: NginxHttpProxyModule</i>